/*
    Copyright 2009 Francesco Massei

    This file is part of mojito webserver.

        Mojito is free software: you can redistribute it and/or modify
    it under the terms of the GNU General Public License as published by
    the Free Software Foundation, either version 3 of the License, or
    (at your option) any later version.

    Mojito is distributed in the hope that it will be useful,
    but WITHOUT ANY WARRANTY; without even the implied warranty of
    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
    GNU General Public License for more details.

    You should have received a copy of the GNU General Public License
    along with Mojito.  If not, see <http://www.gnu.org/licenses/>.
*/

#ifndef H_FPARAMS_H
#define H_FPARAMS_H

#include <mjt_types.h>
#include <lib/mjt_alloc.h>
#include <lib/mjt_iniparse.h>
#include <lib/mjt_logger.h>
#include <lib/mjt_rw.h>

struct fparam_s {
    char_t *pidfile;
    char_t *http_root;
    char_t *default_page;
    char_t *tmp_dir;
    int_t uid, gid;
    int_t listen_port, listen_queue;
    int_t keepalive_timeout;
    char_t *server_meta;
    char_t *logfile, *errfile;
};

struct fparam_s *params_loadFromINIFile(const char_t *fname);
void params_free(struct fparam_s **params);

#endif /* H_FPARAMS_H */
